<template>
	<div class="recommend">
		<div class="Title">热销推荐</div>
		<ul>
			<router-link 
				:to="'/detail/Detail' + item.id"
				tag='li' 
				class="Content border-bottom" 
				v-for='item in recommendList' 
				:key='item.id'
				>
				<img 
				:src="item.imgUrl" 
				class="Content-img"
				>
				<div class="item">
					<p class="item-title">{{item.title}}</p>
					<p class="item-content">{{item.desc}}</p>
					<button class="item-look">查看详情</button>
				</div>
			</router-link>
		</ul>
	</div>
</template>

<script>
export default {
	name: 'Homerecommend',
	props: {
		recommendList: Array
	}

}	
</script>

<style lang="stylus" scoped>
	@import '~styles/mixins.styl'
	.Title
		height: .6rem
		background: #eee
		line-height:.6rem
	.Content
		display: flex
		width: 100%
		padding-bottom: 28%
		height:0
		overflow: hidden
		.Content-img
			height: 2rem
			padding: 0.1rem
		.item
			flex: 1	
			padding: 0.1rem	
			min-width: 0
			.item-title
				line-height:.8rem
				ellipsis()
			.item-content
				line-height:.5rem
				color: #999
				ellipsis()
			.item-look
				background: #009968
				color: #fff
				margin-top: .2rem


</style>